<html>
<head><meta charset="utf-8"><title>performance editing imports · t-compiler/rust-analyzer · Zulip Chat Archive</title></head>
<h2>Stream: <a href="https://rust-lang.github.io/zulip_archive/stream/185405-t-compiler/rust-analyzer/index.html">t-compiler/rust-analyzer</a></h2>
<h3>Topic: <a href="https://rust-lang.github.io/zulip_archive/stream/185405-t-compiler/rust-analyzer/topic/performance.20editing.20imports.html">performance editing imports</a></h3>

<hr>

<base href="https://rust-lang.zulipchat.com">

<head><link href="https://rust-lang.github.io/zulip_archive/style.css" rel="stylesheet"></head>

<a name="203958793"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/185405-t-compiler/rust-analyzer/topic/performance%20editing%20imports/near/203958793" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Jake Goulding <a href="https://rust-lang.github.io/zulip_archive/stream/185405-t-compiler/rust-analyzer/topic/performance.20editing.20imports.html#203958793">(Jul 15 2020 at 14:01)</a>:</h4>
<p>Sometimes when I'm editing a <code>use</code> line, my emacs + lsp-mode + RA will freeze for multiple seconds. Before I go and try to make some reduced case, is this a known issue?</p>



<a name="203958998"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/185405-t-compiler/rust-analyzer/topic/performance%20editing%20imports/near/203958998" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Laurențiu <a href="https://rust-lang.github.io/zulip_archive/stream/185405-t-compiler/rust-analyzer/topic/performance.20editing.20imports.html#203958998">(Jul 15 2020 at 14:02)</a>:</h4>
<p>I haven't noticed that in Code, but see <a href="https://www.reddit.com/r/rust/comments/hqdgli/rustanalyzer_changelog_33/fxxejo0/">https://www.reddit.com/r/rust/comments/hqdgli/rustanalyzer_changelog_33/fxxejo0/</a></p>



<a name="203959263"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/185405-t-compiler/rust-analyzer/topic/performance%20editing%20imports/near/203959263" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Florian Diebold <a href="https://rust-lang.github.io/zulip_archive/stream/185405-t-compiler/rust-analyzer/topic/performance.20editing.20imports.html#203959263">(Jul 15 2020 at 14:04)</a>:</h4>
<p>I think there's a tendency to get a huge amount of syntax errors when editing a <code>use</code> line (if it doesn't have balanced braces), and emacs (especially with the old JSON parser) does not deal well with that</p>



<a name="203959485"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/185405-t-compiler/rust-analyzer/topic/performance%20editing%20imports/near/203959485" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Jonas Schievink  [he/him] <a href="https://rust-lang.github.io/zulip_archive/stream/185405-t-compiler/rust-analyzer/topic/performance.20editing.20imports.html#203959485">(Jul 15 2020 at 14:06)</a>:</h4>
<p>I wonder if better error recovery would be possible in use items, having the entire editor light up when editing imports seems suboptimal</p>



<a name="203959490"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/185405-t-compiler/rust-analyzer/topic/performance%20editing%20imports/near/203959490" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Laurențiu <a href="https://rust-lang.github.io/zulip_archive/stream/185405-t-compiler/rust-analyzer/topic/performance.20editing.20imports.html#203959490">(Jul 15 2020 at 14:06)</a>:</h4>
<p>That was <a href="https://github.com/rust-analyzer/rust-analyzer/issues/3434">https://github.com/rust-analyzer/rust-analyzer/issues/3434</a>, should be fixed in the latest version</p>



<a name="203961220"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/185405-t-compiler/rust-analyzer/topic/performance%20editing%20imports/near/203961220" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Jake Goulding <a href="https://rust-lang.github.io/zulip_archive/stream/185405-t-compiler/rust-analyzer/topic/performance.20editing.20imports.html#203961220">(Jul 15 2020 at 14:20)</a>:</h4>
<p><span class="user-mention silent" data-user-id="129457">Florian Diebold</span> <a href="#narrow/stream/185405-t-compiler.2Fwg-rls-2.2E0/topic/performance.20editing.20imports/near/203959263">said</a>:</p>
<blockquote>
<p>I think there's a tendency to get a huge amount of syntax errors when editing a <code>use</code> line (if it doesn't have balanced braces), and emacs (especially with the old JSON parser) does not deal well with that</p>
</blockquote>
<p>This was my gut suspicion, good to hear other people agree. I started to compile emacs 27 which has an improved parser, but got distracted.</p>



<a name="203961322"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/185405-t-compiler/rust-analyzer/topic/performance%20editing%20imports/near/203961322" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Jake Goulding <a href="https://rust-lang.github.io/zulip_archive/stream/185405-t-compiler/rust-analyzer/topic/performance.20editing.20imports.html#203961322">(Jul 15 2020 at 14:20)</a>:</h4>
<blockquote>
<p>always taking the first 500 errors</p>
</blockquote>
<p>Although this may still be too many for emacs :-)</p>



<a name="203961712"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/185405-t-compiler/rust-analyzer/topic/performance%20editing%20imports/near/203961712" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> matklad <a href="https://rust-lang.github.io/zulip_archive/stream/185405-t-compiler/rust-analyzer/topic/performance.20editing.20imports.html#203961712">(Jul 15 2020 at 14:23)</a>:</h4>
<blockquote>
<p>Although this may still be too many for emacs :-)</p>
</blockquote>
<p>Capped it to 128 half an hour ago :)</p>



<a name="203961840"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/185405-t-compiler/rust-analyzer/topic/performance%20editing%20imports/near/203961840" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Florian Diebold <a href="https://rust-lang.github.io/zulip_archive/stream/185405-t-compiler/rust-analyzer/topic/performance.20editing.20imports.html#203961840">(Jul 15 2020 at 14:24)</a>:</h4>
<p>I'm still using Emacs 26.3, the performance is not great <span aria-label="sad" class="emoji emoji-2639" role="img" title="sad">:sad:</span> but I don't really want to compile Emacs myself, I'm hoping it'll get released very soon now...</p>



<a name="203963767"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/185405-t-compiler/rust-analyzer/topic/performance%20editing%20imports/near/203963767" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Jake Goulding <a href="https://rust-lang.github.io/zulip_archive/stream/185405-t-compiler/rust-analyzer/topic/performance.20editing.20imports.html#203963767">(Jul 15 2020 at 14:39)</a>:</h4>
<p>I was just going to use <code>brew install --HEAD</code> and see how that goes.</p>



<hr><p>Last updated: Aug 07 2021 at 22:04 UTC</p>
</html>